{% extends "layout.html" %}

{% block content %}
    <div class="container-fluid">
    <h1>Sign In</h1>
    <form class="form-horizontal" method="post" action="">
        {{ form.csrf_token }}

        {# 标签导航 #}
        <div class="form-group">
            <ul class="nav nav-tabs">  {# 填充整个导航条：nav-justified #}
                <li role="presentation" class="active"><a href="{{ url_for('auth.index') }}">Index</a></li>
                <li role="presentation"><a href="{{ url_for('auth.phone') }}">Phone</a></li>
                <li role="presentation"><a href="{{ url_for('auth.email') }}">Email</a></li>
            </ul>
        </div>
        <div class="form-group{% if form.account.errors %} has-error{% endif %}">
            {{ form.account.label(class="col-sm-2 control-label") }}
            <div class="col-sm-10">
                {{ form.account(class="form-control", placeholder="Account") }}
                {% for error in form.account.errors %}
                    <span class="help-block">{{ error }}</span>
                {% endfor %}
            </div>
        </div>
        <div class="form-group{% if form.password.errors %} has-error{% endif %}">
            {{ form.password.label(class="col-sm-2 control-label") }}
            <div class="col-sm-10">
                {{ form.password(class="form-control", placeholder="Password", value="123456") }}
                {% for error in form.password.errors %}
                    <span class="help-block">{{ error }}</span>
                {% endfor %}
            </div>
        </div>
        <div class="form-group{% if form.remember.errors %} has-error{% endif %}">
            <div class="col-sm-offset-2 col-sm-10">
                <div class="checkbox">
                    <label>
                        {{ form.remember }} Remember Me
                    </label>
                </div>
            </div>
        </div>
        <div class="form-group">
            <div class="col-sm-offset-2 col-sm-10">
                <button type="submit" class="btn btn-default btn-load" data-loading-text="Sign in..." autocomplete="off">Sign in</button> <a href="#">Lost password?</a>
            </div>
        </div>
    </form>
    <hr/>
    <a type="button" href="{{ url_for('auth.login_qq') }}">QQ</a>
    <a type="button" href="{{ url_for('auth.login_weibo') }}">WeiBo</a>
    <a type="button" href="{{ url_for('auth.login_github') }}">GitHub</a>
    </div>
{% endblock %}